In-Context Learning
定义 Definition
in-context learning(语境内学习/上下文学习):指模型在不更新参数(不进行再训练)的情况下,仅通过输入中的提示、示例与任务描述(即“上下文”)来临时学会如何完成任务的能力。常见于大型语言模型的“few-shot/one-shot”提示场景。(在其他领域里也可泛指“在具体语境中学习”,但现代用法多指机器学习概念。)
发音 Pronunciation
/ɪn ˈkɑːn.tɛkst ˈlɝː.nɪŋ/
/ɪn ˈkɒn.tɛkst ˈlɜː.nɪŋ/
例句 Examples
In-context learning lets the model translate after seeing just a few examples.
语境内学习让模型在只看几个示例后就能进行翻译。
Researchers study in-context learning to understand why some prompts reliably improve accuracy.
研究者研究语境内学习,以理解为什么某些提示能稳定提升准确率。
词源 Etymology
该短语由 in-context(在上下文/语境中) + learning(学习) 组合而成:
- context 源自拉丁语 contextus,本义与“编织在一起、连贯的结构”相关,引申为“语境/上下文”。
- 在机器学习语境中,in-context learning 作为术语在近年因大型语言模型论文与提示学习(prompting)实践而广泛传播,强调“靠上下文示例完成新任务”,而非通过参数更新获得能力。
相关词 Related Words
文学与作品 Literary Works
- Brown et al., “Language Models are Few-Shot Learners” (2020)(GPT-3 论文,系统讨论 few-shot 设置与语境内学习现象)
- Wei et al., “Chain-of-Thought Prompting Elicits Reasoning in Large Language Models” (2022)(通过上下文示例诱导推理步骤,常与语境内学习一起讨论)
- Liu et al., “Pre-train, Prompt, and Predict: A Systematic Survey of Prompting Methods in Natural Language Processing” (2023)(综述提示方法,涵盖与 in-context learning 紧密相关的概念与实践)